home *** CD-ROM | disk | FTP | other *** search
- Frequently Asked Questions (FAQS);faqs.264
-
-
-
- The next two cases are problems even if there is a initialization file for
- your terminal type.
-
- 2. The initialization file for your terminal doesn't bind arrow keys.
-
- If your terminal type is `xterm', you will have to bind the arrow keys
- as in part 1 above, since the xterm.el file doesn't do anything useful.
- There may be other terminal types with the same problem.
-
- 3. Your terminal's arrow keys send individual control characters.
-
- For example, the arrow keys on an ADM-3 send C-h, C-j, C-k, and C-l.
-
- There is not much Emacs can do in this situation, since all the control
- characters except for C-^ and C-\ are already used as Emacs commands.
- It may be possible to convince the terminal to send something else when
- you press the arrow keys; it is worth investigating.
-
- You have to make the hard choices of how to rebind keys to commands to
- make things work the way you want. Another alternative is to start
- learning the standard Emacs keybindings for moving point around: C-b,
- C-f, C-p, and C-n. Personally, I no longer use the arrow keys when
- editing because I have switched keyboards so many times.
-
- 4. Your terminal's arrow keys send sequences beginning with "ESC [".
-
- Due to an extremely poor design decision (ie., these sequences are ANSI
- standard), none of the the terminal-specific initialization files that
- are distributed with Emacs will bind these character sequences to the
- appropriate commands by default. (This also applies to any other
- function keys which generate character sequences starting with "ESC
- [".) This is because it was deemed far more important to preserve the
- binding of M-[ to the backward-paragraph command. It appears that this
- will change in Emacs 19.
-
- Some of the terminal-specific initialization files that come with Emacs
- provide a command enable-arrow-keys that will fix this problem. To get
- this automatically invoked, put this in your .emacs:
-
- (setq term-setup-hook
- (function
- (lambda ()
- (if (fboundp 'enable-arrow-keys) (enable-arrow-keys)))))
-
- We put this in our lisp/default.el file, so users don't have to worry
- about it:
-
- ;; don't override a user's term-setup-hook
- (or term-setup-hook
- (setq term-setup-hook
- (function
- (lambda ()
- (and (fboundp 'enable-arrow-keys)
- ;; don't override a user key mapping
- (eq 'backward-paragraph (lookup-key esc-map "["))
- (enable-arrow-keys))))))
-
- If your terminal type is `sun', you should put this in your .emacs
- instead (or in addition to the above):
-
- (setq sun-esc-bracket t)
-
- It is possible that the terminal-specific initialization file for your
- terminal type was written locally and does not follow the rule
- mentioned above. In this case you may need to inspect it to find out
- how to enable the arrow keys. (Actually, if it was written locally, it
- probably enables the arrow keys by default.)
-
- 136: How do I "swap" two keys?
-
- When Emacs receives a character, you can make Emacs behave as though it
- received another character by setting the value of
- keyboard-translate-table. The following Emacs Lisp will do this for you,
- allowing you to "swap" keys. After arranging for this Lisp to be
- evaluated by Emacs, you can evaluate `(swap-keys ?A ?B)' to swap A and B.
-
- (defun swap-keys (key1 key2)
- "Swap keys KEY1 and KEY2 using map-key."
- (map-key key1 key2)
- (map-key key2 key1))
-
- (defun map-key (from to)
- "Make key FROM behave as though key TO was typed instead."
- (setq keyboard-translate-table
- (concat keyboard-translate-table
- (let* ((i (length keyboard-translate-table))
- (j from)
- (k i)
- (str (make-string (max 0 (- j (1- i))) ?X)))
- (while (<= k j)
- (aset str (- k i) k)
- (setq k (1+ k)))
- str)))
- (aset keyboard-translate-table from to)
- (let ((i (1- (length keyboard-translate-table))))
- (while (and (>= i 0) (eq (aref keyboard-translate-table i) i))
- (setq i (1- i)))
- (setq keyboard-translate-table
- (if (eq i -1)
- nil
- (substring keyboard-translate-table 0 (1+ i))))))
-
- NOTE: You must evaluate the definition of these functions before calling
- them! For example, list the function definitions before their use in your
- .emacs file.
-
- NOTE: These functions take two numbers as arguments. The example above,
- `(swap-keys ?A ?B)' is actually `(swap-keys 65 66)', because `?A' is
- merely notation for 65, the ASCII value of `A'.
-
- NOTE: These functions only work for single characters. You cannot swap
- two multi-character sequences.
-
- 137: How do I produce C-XXX with my keyboard?
-
- For C-@ and C-^, often you can just type Control-2 and Control-6. For
- C-_, you may have to hold down the shift key, typing Control-Shift-Hyphen.
- C-@ can often be generated by typing Control-Space. C-@ is often called
- the NUL character, and has ASCII value 0. C-_ can often be generated by
- typing Control-7 or Control-/. C-? (aka DEL) may be generated by typing
- Shift-BackSpace or Control-BackSpace or a key labelled Delete or Del.
-
- Try Control with all of the digits on your keyboard to see what gets
- generated.
-
- 138: What if I don't have a Meta key?
-
- Instead of typing M-a, you can type "ESC a" instead. In fact, Emacs
- converts M-a internally into "ESC a" anyway (depending on the value of
- meta-prefix-char).
-
- 139: What if I don't have an Escape key?
-
- Type C-[ instead. This should send ASCII code 27 just like an Escape
- key would. Try also C-;.
-
- 140: How do I type DEL on PC terminal emulators?
-
- Some IBM PC compatibles do not have a key labeled `Del' or `Delete' {is
- this true?}. Those that do generally have it in an inconvenient location.
- (Also, in some terminal emulators, the `Del' key does not transmit DEL.)
- The result is the standard "BackSpace invoking help" problem (see question
- 133).
-
- The usual solution, suggested by Michael Covington
- <mcovingt@aisun1.ai.uga.edu>, is to somehow tell the terminal emulator
- program that BackSpace should transmit DEL. Read the program's manual.
- Shift-BackSpace or Control-BackSpace may send DEL. The `Del' key may only
- send DEL if the NumLock key hasn't been pressed.
-
- 141: Can I make my `Compose Character' key behave like a Meta key?
-
- On a dumb terminal such as a VT220, no. It is rumored that certain VT220
- clones could have their Compose key configured this way. If you're using
- X, you might be able to do this with the `xmodmap' program (this is
- what I do).
-
- 142: How do I bind a combination of modifier key and function key?
-
- Unless you're using Emacs under emacstool (or xvetool?), have a working !
- version of x-rebind-key (see question 128), or are using Emacs 19 (Lucid +
- Emacs), you can't do this with Emacs alone. +
-
- If you are using emacstool, Emacs sees different character sequences for
- the combination of a modifier and a function key from what it sees for the
- function key alone. See etc/emacstool.1 for more information. Since
- Emacs sees different character sequences, you can bind these different
- sequences to different commands.
-
- If you are running Emacs inside a terminal emulator window like xterm, you
- can modify its translation tables to make it generate different character
- sequences for the combination of a modifier and a function key. For
- example, this X resource setting:
-
- XTerm.VT100.Translations: #override \
- Shift<KeyPress>F1: string(0x1b) string("[xyzzy")
-
- makes Shift-F1 generate the character sequence "ESC [ xyzzy". You can
- bind these character sequences in Emacs as normal. Nick Ruprecht
- <ruprecht@informatik.uni-freiburg.de> has written an extensive X
- translation mapping for xterm that does this. {Does this have an FTP
- site?}
-
- If you have x-rebind-key, you can have any arbitrary combination of +
- modifiers with a key replaced by any sequence of "normal" characters. For +
- example, this makes Shift-Return behave as though you had typed "C-x C-e" +
- (example from Jerry Graves): +
- +
- (x-rebind-key "Return" 'shift "\C-x\C-e") +
- +
- In Emacs 19 (Lucid Emacs), you can bind Meta-Left-Arrow like this (example +
- from Jamie Zawinski): +
- +
- (global-set-key '(meta left) 'backward-word) +
- +
- With the last two methods, use `xmodmap' and `xev' to discover the keysym +
- and modifier names. +
-
- 143: Why doesn't my Meta key work in an xterm window?
-
- Try all of these methods before asking for further help:
-
- * You may have big problems using `mwm' as your window manager. {Does
- anyone know a good generic solution to allow the use of the Meta key in
- Emacs with mwm?}
-
- * For X11R4: Make sure it really is a Meta key. Use `xev' to find out
- what keysym your Meta key generates. It should be either Meta_L or
- Meta_R. If it isn't, use xmodmap to fix the situation.
-
- * Make sure the pty the xterm is using is passing 8 bit characters.
- `stty -a' (or `stty everything') should show `cs8' somewhere. If it
- shows `cs7' instead, use `stty cs8 -istrip' (or `stty pass8') to fix
- it.
-
- * If there is an rlogin connection between the xterm and the Emacs, the
- `-8' argument may need to be given to rlogin to make it pass all 8
- bits of every character.
-
- * If the Emacs is running under Ultrix, it is reported that evaluating
- (set-input-mode t nil) helps.
-
- * If all else fails, you can make xterm generate "ESC W" when you type
- M-W, which is the same conversion Emacs would make if it got the M-W
- anyway. In X11R4, the following resource specification will do this:
-
- XTerm.VT100.EightBitInput: false
-
- (This changes the behavior of the insert-eight-bit action.)
-
- With older xterms, you can specify this behavior with a translation:
-
- XTerm.VT100.Translations: #override \
- Meta<KeyPress>: string(0x1b) insert()
-
- You might have to replace `Meta' with `Alt'.
-
- 144: Why doesn't my ExtendChar key work as a Meta key under HP-UX 8.0?
-
- This is a result of an internationalization extension in X11R4 and the
- fact that HP is now using this extension. Emacs assumes that
- XLookupString returns the same result regardless of the Meta key state
- which is no longer necessarily true. Until Emacs is fixed, the temporary
- kludge is to run this command after each time the X server is started but
- preferably before any xterm clients are:
-
- xmodmap -e 'remove mod1 = Mode_switch'
-
- NOTE: This will disable the use of the extra keysyms systemwide, which
- may be undesirable if you actually intend to use them.
-
- 145: Where can I get key bindings to make Emacs emulate WordStar?
-
- There is a package `wordstar' by Jim Frost <jimf@saber.com> and
- `ws-mode.el' by Juergen Nickelsen <nickel@cs.tu-berlin.de>. Check in the
- Emacs Lisp Archive (see question 89).
-
- 146: Where can I get an XEDIT emulator for Emacs?
-
- This question comes up once every couple of months. I have never seen a
- positive reply, so I presume no one has ever written one.
-
-
-
- Using Emacs with Alternate Character Sets
-
- 147: How do I make Emacs display 8-bit characters?
-
- There is a patch called the `8-bit ctl-arrow patch' that allows Emacs to
- display characters with codes from 128 to 255. {The original appears to
- have been by Kenneth Cline <cline@proof.ergo.cs.cmu.edu>.} Partially based
- on Johan Widen's earlier work, Johan Vromans <jv@mh.nl> has updated this
- patch for Emacs 18.58 along with some other 8-bit improvements.
-
- Anonymous FTP:
- /ftp.eu.net:gnu/emacs/FP-EightBit.Z +
- /ftp.urc.tue.nl:pub/tex/emacs/FP-EightBit +
- /cs.purdue.edu:pub/ygz/cemacs.tar.Z:cemacs/8bit-patch-18.57 +
- /sics.se:archive/emacs-18.55-8bit-diff +
- /laas.laas.fr:pub/emacs/patch-8bit-18.55 !
- /laas.laas.fr:pub/emacs/patch-8bit-18.57 !
-
- Via e-mail:
- To: mail-server@sics.se
- body: send emacs-18.55-8bit-diff
-
- Anders Edenbrandt <anderse@dna.lth.se> has produced a more comprehensive
- patch for Emacs 18.57 that allows for 8-bit input and output.
-
- Anonymous FTP:
- /sics.se:archive/emacs-8bit-diff-lth +
- /gatekeeper.dec.com:pub/GNU/DS-emacs-18.57-8bit-diff-lth +
-
- The most comprehensive patches for 8-bit output are by Howard Gayle
- (originally for Emacs 18.55. These patches allow displaying any arbitrary
- string for a given 8-bit character (except TAB and C-j). Also supported
- is defining the sorting order and the uppercase and lowercase
- translations. It is reported that the 8-bit character support in Emacs 19
- is largely based on these patches. Thomas Bellman
- <Bellman@lysator.liu.se> has updated these patches for Emacs 18.57.
-
- Anonymous FTP:
- /sics.se:archive/emacs-gayle.tar.Z (patches for 18.55) +
- /ftp.lysator.liu.se:pub/emacs/gayle-18.57.diff.tar.Z (patches) +
- /ftp.lysator.liu.se:pub/emacs/emacs-18.57-gayle.tar.Z (patched Emacs) +
-
- I am not sure if Epoch can display 8-bit characters as is. Lucid Emacs
- has the ctl-arrow patch installed. Nemacs displays 8-bit characters, and
- it may be useful for displaying the 8-bit ISO-8859 alphabet, but I don't
- know for sure (see question 149).
-
- 148: How do I input 8-bit characters?
-
- Minor modes for ISO Latin-1 that allow one to easily input this character
- set have been written by several people. Such modes have been written by
- Matthieu Herrb <matthieu@laas.fr> (laas.laas.fr:pub/emacs/iso-latin-1.el),
- Johan Vromans <jv@mh.nl> {FTP site??}, and Marc Shapiro
- <shapiro@sor.inria.fr> {FTP site??}.
-
- These approaches differ from the one taken by Anders Edenbrandt in that
- his method uses direct 8-bit input, while these methods use a compose
- sequence for 8-bit characters. {I have heard conflicting reports on
- whether this results in losing the Meta key. Perhaps this depends on
- whether Emacs is running under X. Can someone resolve this?}
-
- Karl Heuer <karl@haddock.ima.isc.com> is said to have a patch to allow
- 8-bit input. Georg-Wilhelm Koltermann <gwk@crmunich0.cray.com> also has a
- patch for either 18.57 or 18.58 that allows 8-bit input.
-
- Epoch comes with a patch that allows it to input 8-bit characters, but it
- is not enabled by default. {Is this right?}
-
- Jamie Zawinski says: +
- +
- Lucid GNU Emacs allows the input of any ISO-8859/1 keysyms that your +
- keyboard generates (see xmodmap), and contains a package that implements +
- a DEC/OpenWindows-like "Compose" key for systems which don't have one. +
-
- 149: Where can I get an Emacs that can handle kanji characters?
-
- Nemacs 3.3.2 (Nihongo GNU Emacs) is a modified version of GNU Emacs 18.55
- that handles kanji characters. It is available via anonymous FTP: !
- !
- /crl.nmsu.edu:pub/misc/nemacs-3.3.2.tar.Z !
- /uhccux.uhcc.hawaii.edu:editors/Nemacs-3.3.2/ !
- /miki.cs.titech.ac.jp:JAPAN/nemacs/nemacs-3.3.2.tar.Z !
-
- You might also need files for "wnn", a kanji input method
- (wnn-4.0.3{-README,.tar.Z} {on which machine?}). You need a terminal (or
- terminal emulator) that can display text encoded in JIS, Shift-JIS, or EUC
- (Extended Unix Code), or the ability to run Nemacs as a direct X Window
- client.
-
- 150: Where can I get an Emacs that can handle Chinese?
-
- `cemacs' by Stephen G. Simpson <simpson@math.psu.edu> is a patch to Emacs
- 18.57 (the ctl-arrow patch) and some Emacs Lisp code that combined with
- Cxterm allows using Chinese characters. It is available via anonymous
- FTP: !
- !
- /crl.nmsu.edu:pub/chinese/cemacs.tar.Z !
- /cs.purdue.edu:pub/ygz/cemacs.tar.Z !
-
- Cxterm is available from the same place: !
- !
- /cs.purdue.edu:pub/ygz/cxterm-11.5.1.tar.Z !
-
- 151: Where is an Emacs that can handle Semitic (right-to-left) alphabets?
-
- Joel M. Hoffman <joel@wam.umd.edu> writes:
-
- A couple of years ago a wrote a hebrew.el file that allows right-to-left
- editing of Hebrew. I relied on the hardware to display the Hebrew
- letters, given the right codes, but not for any right-to-left support;
- the hardware also doesn't have to send any specific char. codes. Emacs
- keeps track of when the user is typing Hebrew vs. English. (The VT-*
- terminals in Israel contain built-in support for Hebrew.)
-
- To get it to work I had to modify only a few lines of GNU Emacs's source
- code --- just enough to make it 8-bit clean.
-
- [and in a separate message:]
-
- It doesn't produce time-order ["sefer" format] (I wouldn't recommend
- trying that with emacs, because converting time-order to screen-order
- with arbitrarily long lines is a bit tricky), but I also concocted a
- quick filter to convert screen-order into time-order. I'll be happy to
- send you the requisite files if you want them. If you're using it for
- anything large, however, you'll want something that works better.
-
- Joel Hoffman has also written a "bi-directional bi-lingual Emacs-like"
- editor for MS-DOS named Ibelbe (Itty Bitty Emacs-Like Bidirectional
- Editor). Ibelbe is written in Turbo Pascal and comes with source code.
- Here is the description:
-
- Ibelbe looks like emacs (it even has a minibuffer and filename
- completion), and fully supports both right-to-left and left-to-right
- editing. Other than an EGA monitor or better, no special hardware is
- required. You will need an EGA Hebrew font to use Ibelbe with Hebrew.
-
- Anonymous FTP:
- /israel.nysernet.org:israel/msdos/ibelbe.zip !
- /israel.nysernet.org:israel/msdos/hebfont.zip !
-
- Joseph Friedman <yossi@deshaw.com, yossi@Neon.Stanford.EDU> has written
- patches for Emacs 18.55 and 18.58 that provide Semitic language support
- under X Windows.
-
- Warren Burstein <warren@itex.jct.ac.il> says he has mapped 7-bit keys by
- modifying self-insert-command "for Hebrew input on 7-bit keyboards".
-
- A good suggestion is to query archie for files named with `hebrew'.
-
- Xref: bloom-picayune.mit.edu gnu.emacs.help:7403 comp.emacs:15252 gnu.emacs.gnus:2879 news.answers:3117
- Path: bloom-picayune.mit.edu!enterpoop.mit.edu!snorkelwacker.mit.edu!eff!sol.ctr.columbia.edu!spool.mu.edu!hri.com!noc.near.net!news.bbn.com!bu.edu!bigbird!jbw
- From: jbw@bigbird.bu.edu (Joe Wells)
- Newsgroups: gnu.emacs.help,comp.emacs,gnu.emacs.gnus,news.answers
- Subject: GNU Emacs FAQ (5/5, 152-177): Mail and News
- Summary: READ BEFORE POSTING. A regularly posted list of answers to frequently
- asked questions (FAQs) about GNU Emacs and many Emacs Lisp programs.
- Contains pointers to other resources. Follow "References:" link for
- more metainfo.
- Keywords: gnu emacs faq answers frequently asked questions periodic
- Message-ID: <GNU-Emacs-FAQ-5.1992.09.22.011020@bigbird.bu.edu>
- Date: 22 Sep 92 01:10:20 GMT
- Expires: 21 Nov 92 01:10:20 GMT
- References: <GNU-Emacs-FAQ-0.1992.09.22.011020@bigbird.bu.edu>
- Sender: news@bu.edu
- Reply-To: gnu-emacs-faq-maintainers@bigbird.bu.edu
- Followup-To: poster
- Organization: GNU's Not UNIX
- Lines: 443
- Approved: news-answers-request@mit.edu
- Supersedes: <GNU-Emacs-FAQ-5.1992.06.28.234430@bigbird.bu.edu>
-
- Archive-Name: GNU-Emacs-FAQ/part5
- Last-Modified: Tue, 22 Sep 1992 01:09:59 GMT
- Last-Posted: Tue, 22 Sep 1992 01:10:20 GMT
-
- GNU Emacs FAQ: Mail and News
-
- This portion of the GNU Emacs FAQ list is cross-posted to `gnu.emacs.gnus'
- because many of the questions herein deal with GNUS. See `gnu.emacs.help' for
- the rest of the FAQ list.
-
- If you are viewing this text in a GNU Emacs Buffer, you can type "M-2 C-x $" to
- get an overview of just the questions. Then, when you want to look at the text
- of the answers, just type "C-x $".
-
- To search for a question numbered XXX, type "M-C-s ^XXX:", followed by a C-r if
- that doesn't work, then type ESC to end the search.
-
- A `+' in the 78th column means something was inserted on the line. A `-' means
- something was deleted and a `!' means some combination of insertions and
- deletions occurred.
-
- Full instructions for getting the latest FAQ are in question 22. Also see the
- `Introduction to news.answers' posting in the `news.answers' newsgroup, or send
- e-mail to `mail-server@rtfm.mit.edu' with `help' on a body line, or use FTP,
- WAIS, or Prospero to rtfm.mit.edu.
-
-
-
- Mail and News
-
- 152: How do I change the included text prefix in mail/news followups?
-
- Many people want Emacs to prefix included text with something like ` > '
- instead of with three spaces. One way is to change the code of the
- function `mail-yank-original' in lisp/sendmail.el that prefixes with
- spaces. A more flexible solution is to use Supercite, which provides wide
- configurability in how you format included text in replies. See question
- 107. Both of these solutions work for RMAIL and GNUS.
-
- A related problem is how to prevent Emacs from including various headers
- of the replied-to message. For this, you should set the value of
- mail-yank-ignored-headers, which takes a regexp value.
-
- 153: How do I save a copy of outgoing mail?
-
- Two methods:
-
- 1. (setq mail-self-blind t) will result in a `BCC:' header line with your
- address being added to mail composition buffers. This will cause the
- mail system to send a copy of the mail back to you.
-
- 2. (setq mail-archive-file-name (expand-file-name "~/outgoing")) will
- result in an `FCC:' header line with the pathname of ~/outgoing being
- added to mail composition buffers. When you send the mail, Emacs will
- save a copy of the mail in the file ~/outgoing and then strip off the
- `FCC:' line before actually sending.
-
- WARNING: There is a bug in Emacs 18.58 that prevents mail readers such
- as RMAIL from reading the saved mail messages individually. See
- question 155.
-
- WARNING: If you are visiting the file ~/outgoing at the time you send
- the mail, this can cause a variety of horrible problems. Jamie +
- Zawinski has written a solution for this. +
-
- It does not work to put `set record filename' in the .mailrc file.
-
- 154: Why doesn't Emacs expand my aliases when sending mail?
-
- * You must separate multiple addresses in the headers of the mail buffer
- with commas. This is because Emacs supports RFC822 standard addresses
- like this one:
-
- To: Willy Smith <wks@xpnsv.lwyrs.com>
-
- However, you do not need to separate addresses with commas in your
- .mailrc file.
-
- WARNING: Emacs breaks up aliases in the .mailrc file into multiple
- addresses both on commas and on whitespace, regardless of any use of
- quotes. This is probably a bug. You can get around this by directly
- setting the value of mail-aliases.
-
- * Emacs normally only reads the `.mailrc' file once per session, when you
- start to compose your first mail message. If you edit .mailrc, you can
- type "M-ESC (build-mail-aliases) RET" to make Emacs reread .mailrc.
- (You have to include the parentheses where they are shown!)
-
- * Emacs does not interpret vendor-specific additions to the format of the
- .mailrc file such as the `source' command. It also ignores any `set'
- commands. The only commands it looks at are `alias' and `group'
- commands.
-
- 155: Why does RMAIL think all my saved messages are one big message?
-
- There is a bug for FCC-ed messages in Emacs 18.58 where it adds a timezone
- on the "From " line after the year instead of before the year. (Before it
- didn't add the timezone at all.) This is incompatible with the standard
- format for the "From " line, and RMAIL in particular can no longer
- distinguish between the messages. Karl Berry <karl@cs.umb.edu>, Felix Lee
- <flee@cs.psu.edu>, Nick Gianniotis <nico@japan.sbi.com> and many
- others have all posted patches for this. Karl's is the simplest and just
- stops Emacs from adding the timezone:
-
- >*** ./ORIG/sendmail.el Tue Jan 28 16:22:56 1992
- >--- ./sendmail.el Thu May 14 18:23:48 1992
- >***************
- >*** 285,287 ****
- > (insert "\nFrom " (user-login-name) " "
- >! (current-time-string) " " timezone "\n")
- > (insert-buffer-substring rmailbuf)
- >--- 285,287 ----
- > (insert "\nFrom " (user-login-name) " "
- >! (current-time-string) "\n")
- > (insert-buffer-substring rmailbuf)
-
- 156: How can I sort the messages in my RMAIL folder?
-
- Use rmailsort.el by Masanobu Umeda.
-
- 157: Why does RMAIL need to write to /usr/spool/mail?
-
- This is the behavior of the `movemail' program which RMAIL uses. This
- indicates that movemail is configured to use lock files.
-
- RMS writes:
-
- Certain systems require lock files to interlock access to mail files.
- On these systems, movemail must write lock files, or you risk losing
- mail. You simply must arrange to let movemail write them.
-
- Other systems use the flock system call to interlock access. On these
- systems, you should configure movemail to use flock.
-
- 158: How do I recover my mail files after RMAIL munges their format?
-
- Users who just want to try RMAIL out to see how it works end up trapped
- using it because saved mail in their `mbox' file has been converted into
- an incompatible format (BABYL) that only RMAIL understands. RMAIL
- provides no obvious way to reverse this transformation. Kyle Jones has +
- aptly named this "the great Emacs Mail Eating Monster". To convert a mail +
- file back to standard Unix format, there are several methods:
-
- * Use the rmail-output ("C-o") command within RMAIL on each message in the
- file. First use M-x rmail or M-x rmail-input to visit the RMAIL file in
- Rmail mode. Type "1 j" to go to the first message. Use the C-o command
- to output the message to a Unix format file. Type "n" to go to the next
- message. Repeat.
-
- * If the file contains hundreds of messages, you may not want to repeat
- this for all of them. Instead of the above, after getting to the first
- message type this (where "mbox" is the file you want to put the messages
- in):
-
- C-x ( C-o mbox RET M-s ^From: RET M-0 C-x )
-
- (The rmail-search command ("M-s") is used instead of just "n" because it
- is the only command which will cause an error when it reaches the last
- message in the file, which is necessary to terminate the keyboard macro.
- This will fail if there are messages in the file that don't have a
- `From:' header. This assumes rmail-delete-after-output is nil.)
-
- It is wise to save a copy of the RMAIL file first, in case you make a
- mistake.
-
- * There are software packages available for converting files or even
- entire directories of BABYL files to standard Unix format. These are
- helpful in this situation, but are intended mainly for people who have
- used RMAIL for a long time and are converting to some other mail reader.
- Lookup `rmail', `vm', and `babyl' in the Emacs Lisp Archive (see
- question 89).
-
- You may wish to disable RMAIL to avoid accidentally destroying your mbox
- file (I have this in my .emacs):
-